﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations.Schema;
using System.Text;
using Abp.Domain.Entities.Auditing;
using FwProject.Authorization.Users;
using FwProject.Core.Restaurant;

namespace FwProject.Restaurant
{
    [Table("DepositInfo")]
    public class DepositInfo : FullAuditedEntity<Guid>
    {
        /// <summary>
        /// 工厂编号
        /// </summary>
        public Guid FactoryinfoId { get; set; }
        /// <summary>
        /// 餐厅编号
        /// </summary>
        public Guid RestaurantId { get; set; }
        [ForeignKey("RestaurantId")]
        public virtual RestaurantInfo RestaurantInfoModel { get; set; }
        /// <summary>
        /// 账户编号
        /// </summary>
        public Guid? CapitalAccountId { get; set; }
        /// <summary>
        /// 账号
        /// </summary>
        public string AccountNo { get; set; }
        /// <summary>
        /// 账户名称
        /// </summary>
        public string AccountName { get; set; }
        /// <summary>
        /// 押金单号
        /// </summary>
        public string CreationNumber { get; set; }
        /// <summary>
        /// 金额
        /// </summary>
        public decimal Money { get; set; } = 0.0m;
        /// <summary>
        /// 经办人编号
        /// </summary>
        public long? AgentPeoperUserId { get; set; }
        /// <summary>
        /// 经办人姓名
        /// </summary>
        public string AgentPeoper { get; set; }
        /// <summary>
        /// 备注
        /// </summary>
        public string RemarkContent { get; set; }
        /// <summary>
        /// 收退类型
        /// </summary>
        public DepositType DepositType { get; set; } = DepositType.收押金;

        public DepositStatus DepositStatus { get; set; } = DepositStatus.未提交;

        /// <summary>
        /// 押金收/退时间
        /// </summary>
        public DateTime DepositTime { get; set; }
    }
    public enum DepositType
    {
        收押金 = 0,
        退押金 = 1
    }

    public enum DepositStatus
    {
        未提交 = 0,
        已提交 = 1,
        已审核 = 2,
        退回 = 3
    }
}
